package io_exercise;

import java.io.Serializable;
import java.util.Arrays;

public class Student2 implements Serializable {
    private String name2;
    private int age2;
    private String gender2;
    private transient String[] otherInfo;

    public Student2() {
    }

    public Student2(String name2, int age2, String gender2, String[] otherInfo) {
        this.name2 = name2;
        this.age2 = age2;
        this.gender2 = gender2;
        this.otherInfo = otherInfo;
    }

    @Override
    public String toString() {
        return "Student2{" +
                "name2='" + name2 + '\'' +
                ", age2=" + age2 +
                ", gender2='" + gender2 + '\'' +
                ", otherInfo=" + Arrays.toString(otherInfo) +
                '}';
    }

    public String getName2() {
        return name2;
    }

    public void setName2(String name2) {
        this.name2 = name2;
    }

    public int getAge2() {
        return age2;
    }

    public void setAge2(int age2) {
        this.age2 = age2;
    }

    public String getGender2() {
        return gender2;
    }

    public void setGender2(String gender2) {
        this.gender2 = gender2;
    }

    public String[] getOtherInfo() {
        return otherInfo;
    }

    public void setOtherInfo(String[] otherInfo) {
        this.otherInfo = otherInfo;
    }
}
